<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div id="app">
        用户名：
        <input type="text" v-model="msg" @keyup.aaa = 'handle'> 
    </div>
    <script src="../node_modules/vue/dist/vue.min.js"></script>
    <script>
        // 自定义按键修饰符
        Vue.config.keyCodes.aaa = 65;
        var vm = new Vue({
            el:'#app',
            data:{
               msg:'' 
            },
            methods: {
                handle:function(){
                    console.log(this.msg);
                }
            },
        })
    </script>
</body>
</html>